package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import static org.jsola.hr.example.NewsFileExample.E_NAME;
import static org.jsola.hr.example.NewsFileExample.E_NEWS_INFO_ID;
import static org.jsola.hr.example.NewsFileExample.E_SORT;
import static org.jsola.hr.example.NewsFileExample.E_URL;
import static org.jsola.hr.example.NewsFileExample.M_NAME_MAX;
import static org.jsola.hr.example.NewsFileExample.M_NEWS_INFO_ID_MAX;
import static org.jsola.hr.example.NewsFileExample.M_URL_MAX;
import static org.jsola.hr.example.NewsFileExample.N_NAME;
import static org.jsola.hr.example.NewsFileExample.N_NEWS_INFO_ID;
import static org.jsola.hr.example.NewsFileExample.N_SORT;
import static org.jsola.hr.example.NewsFileExample.N_URL;

/**
 * 官网新闻内容附带的附件
 *
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【官网新闻内容附带的附件】的参数")
@Data
public class NewsFileAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_SORT, example = E_SORT)
    private Integer sort;

    @ApiModelProperty(notes = N_NEWS_INFO_ID, example = E_NEWS_INFO_ID)
    @Length(max = 32, message = M_NEWS_INFO_ID_MAX)
    private String newsInfoId;

    @ApiModelProperty(notes = N_URL, example = E_URL)
    @Length(max = 200, message = M_URL_MAX)
    private String url;

    @ApiModelProperty(notes = N_NAME, example = E_NAME)
    @Length(max = 50, message = M_NAME_MAX)
    private String name;


}

